﻿#region Copyright information
// 
// Copyright © 2005-2013 Yongkee Cho. All rights reserved.
// 
// This code is a part of the Biological Object Library and governed under the terms of the
// GNU Lesser General  Public License (LGPL) version 2.1 which accompanies this distribution.
// For more information on the LGPL, please visit http://bol.codeplex.com/license.
// 
// - Filename: DnaSequence.cs
// - Author: Yongkee Cho
// - Email: yongkeecho@gmail.com
// - Date Created: 2013-01-24 4:34 PM
// - Last Modified: 2013-01-25 3:59 PM
// 
#endregion
using System.Collections.Generic;
using BOL.Maths.Distributions;

namespace BOL.Algorithms.StateMachines.Models
{
    /// <summary>
    /// Models an espresso machine.
    /// </summary>
    public class DnaSequence : MarkovChain<char>
    {
        public DnaSequence()
            : base(
                new [] { 'A', 'C', 'G', 'T' },
                new Dictionary<char, IDistribution<char>>
                {
                    { 'A', new CategoricalDistribution<char>(new Dictionary<char, double> { { 'A', 0.6 }, { 'C', 0.1 }, { 'G', 0.1 }, { 'T', 0.2 } }) },
                    { 'C', new CategoricalDistribution<char>(new Dictionary<char, double> { { 'A', 0.1 }, { 'C', 0.5 }, { 'G', 0.3 }, { 'T', 0.1 } }) },
                    { 'G', new CategoricalDistribution<char>(new Dictionary<char, double> { { 'A', 0.05 }, { 'C', 0.2 }, { 'G', 0.7 }, { 'T', 0.05 } }) },
                    { 'T', new CategoricalDistribution<char>(new Dictionary<char, double> { { 'A', 0.4 }, { 'C', 0.05 }, { 'G', 0.05 }, { 'T', 0.5 } }) }
                }
            )
        {
        }
    }
}